-
Notifications
You must be signed in to change notification settings - Fork 2.8k
fix(build-std): std link metadata propagate to user #16496
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I can understand adding a regression test for the panic but by adding a test that we aren't passing up metadata, we are saying it isn't supported which is the question at hand. Only metadata for direct deps are exposed. Opaque dependencies should be able to pass this information up. |
|
Thanks. That is reasonable. The link metadata behavior is restore, and for any metadata that leaves for follow-up. |
| @@ -0,0 +1,3 @@ | |||
| fn main() { | |||
| println!("cargo:compiler-rt=foo"); | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There a reason you are using the old syntax instead of cargo::compiler-rt=foo? I at first thought this was some existing directive :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reflecting how std does it
Updated to new cargo::metadata syntax. It shouldn't affect the test behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to merge with however you resolve my comment
This reverts rust-lang#16489 though currently only compiler_builtins has link metadata `-Zany-build-script-metadata` is not supported yet for build-std
|
This PR was rebased onto a different master commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
Update cargo submodule 15 commits in 8c133afcd5e0d69932fe11f5907683723f8d361d..85eff7c80277b57f78b11e28d14154ab12fcf643 2026-01-09 03:50:15 +0000 to 2026-01-15 16:18:08 +0000 - fix(lockfile): switch to `resolver.lockfile-path` config (rust-lang/cargo#16510) - Moved build-script bins to `deps` directory (rust-lang/cargo#16515) - Invalidate the whole build cache when `-Zno-embed-metadata` changes (rust-lang/cargo#16513) - Do not create examples dir in build dir with new layout (rust-lang/cargo#16514) - fix(git): avoid partial oid got zero padded (rust-lang/cargo#16511) - Optimize cargo locate-project --workspace (rust-lang/cargo#16423) - chore: Update typos (rust-lang/cargo#16507) - refactor(git): remove unnecessary serialization (rust-lang/cargo#16505) - fix(build-std): std link metadata propagate to user (rust-lang/cargo#16496) - Improve error message for missing dependencies (rust-lang/cargo#16500) - fix: preserve `dep_name` for build script metadata (rust-lang/cargo#16494) - refactor(toml): clarify `to_dependency` for config patch (rust-lang/cargo#16492) - Add `--id` flag to `cargo report timings` and `cargo report rebuilds` (rust-lang/cargo#16490) - Display lockfile path in very verbose mode when blocking (rust-lang/cargo#16491) - fix(info): resolve underscore vs hyphen mismatch in schema lookup (rust-lang/cargo#16455) r? ghost
What does this PR try to resolve?
This reverts #16489
though currently only compiler_builtins has link metadata
-Zany-build-script-metadatais not supported yet for build-stdHow to test and review this PR?
Test passes.